import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

/**
 * @projectName: com.xiayuanxing.designPattern
 * @className: Caretaker
 * @author: xiayuanxing
 * @description: TODO
 * @date: 2022/1/17 14:09
 * @version: 1.0
 */
public class Caretaker {

    //如果只保存一次状态
    private Memento memento;

    //对gameRole保存多次状态
    //private List<Memento> mementos;

    //对多个游戏角色保存多个状态
    //private HashMap<String,ArrayList<Memento>> rolesMementos;


    public Memento getMemento() {
        return memento;
    }

    public void setMemento(Memento memento) {
        this.memento = memento;
    }
}
